# Maintainer: Giovanni Scafora <giovanni@archlinux.org>
# Contributor: suasageandeggs <s_stoakley@hotmail.co.uk>
# Contributor: Michael Fellinger <manveru@www.weez-int.com>

pkgname=libtommath
pkgver=1.2.0
pkgrel=3
pkgdesc="Highly optimized and portable routines for integer based number theoretic applications"
url="http://www.libtom.org/"
license=('custom')
arch=('x86_64')
depends=('glibc')
source=("https://github.com/libtom/libtommath/releases/download/v$pkgver/ltm-$pkgver.tar.xz")
sha256sums=('b7c75eecf680219484055fcedd686064409254ae44bc31a96c5032843c0e18b1')

build() {
  cd $pkgname-$pkgver

  make -f makefile.shared IGNORE_SPEED=1
}

package() {
  cd $pkgname-$pkgver

  make -f makefile.shared PREFIX=/usr DESTDIR="$pkgdir" INSTALL_GROUP=root install
  install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
